﻿@model MvcOrganizer.Models.TvShow

@{
    ViewBag.Title = "Edit";
}

<h2>Edit</h2>

@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)

    <div class="form_settings">
        <p>
            @Html.LabelFor(model => model.Title)
            @Html.EditorFor(model => model.Title)
            @Html.ValidationMessageFor(model => model.Title)
        </p>
        <p>
            @Html.LabelFor(model => model.ReleaseDay)
            @Html.DropDownListFor(model => model.ReleaseDay, new SelectList(new List<Object>{ 
                       new { value = "Monday" , text = "Monday"  },
                       new { value = "Tuesday" , text = "Tuesday" },
                       new { value = "Wednesday" , text = "Wednesday"},
                       new { value = "Thursday" , text = "Thursday"},
                       new { value = "Friday" , text = "Friday"},
                       new { value = "Saturday" , text = "Saturday"},
                       new { value = "Sunday" , text = "Sunday"}
                    }, "value", "text", 0))
            @Html.ValidationMessageFor(model => model.ReleaseDay)
        </p>
        <p>
            @Html.LabelFor(model => model.Season)
            @Html.EditorFor(model => model.Season)
            @Html.ValidationMessageFor(model => model.Season)
        </p>
        <p>
            @Html.LabelFor(model => model.Episode)
            @Html.EditorFor(model => model.Episode)
            @Html.ValidationMessageFor(model => model.Episode)
        </p>
        <p>
            @Html.LabelFor(model => model.Genre)
            @Html.EditorFor(model => model.Genre)
            @Html.ValidationMessageFor(model => model.Genre)
        </p>
        <p>
            @Html.LabelFor(model => model.Rating)
            @Html.EditorFor(model => model.Rating)
            @Html.ValidationMessageFor(model => model.Rating)
        </p>
        <p style="padding-top: 15px">
            <span>&nbsp;</span>
            <input type="submit" value="Save" class="submit" />
        </p>
    </div>
}

<div>
    @Html.ActionLink("Back to List", "Index")
</div>
